package com.easy.service.impl;

import com.easy.bean.CheckIns;
import com.easy.dao.ICheckInksDao;
import com.easy.service.ICheckIns;
import com.easy.util.Page;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CheckInsImpl implements ICheckIns {
    @Autowired
    ICheckInksDao dao;

    @Override
    public int addCheckIns(CheckIns checkIns) {
        int count=dao.addCheckIns(checkIns);
        return count;
    }

    public CheckIns getCheckIns(int id){
        return dao.getCheckIns(id);
    }

    @Override
    public int delCheckIns(int id) {
        int count= dao.delCheckIns(id);
        return count;
    }

    @Override
    public int editCheckIns(CheckIns checkIns) {
        int count=dao.editCheckIns(checkIns);
        return count;
    }

    @Override
    public List<CheckIns> searchCheckIns(CheckIns checkIns, Page page) {
        return dao.searchCheckIns(checkIns,page);
    }

    @Override
    public int getCount(CheckIns checkIns) {
        return dao.getCount(checkIns);
    }

}
